Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move tscoverage en/decoders from riak_kv over here #190

Merged
merged 2 commits into from
Apr 19, 2016

Conversation

hmmr
Copy link
Contributor

@hmmr hmmr commented Apr 15, 2016

Move the code assembling #tscoverageresp from riak_kv here. The callbacks in the common module serving both PB and TTB messages need to only ever return plain Erlang terms. For PB messages, appropriate codecs will be used (from riak_pb_ts_codec), while TTB messages are transmitted (as if) without any conversions.

This PR is required for basho/riak_kv#1382 and basho/riak-erlang-client#277 to pass the tests in basho/riak_test#1037.

Anticipating get_coverage conversion to TTB, where native terms are sent
over the wire, riak_kv_ts_svc needs to be agnostic to all internals of
#ts* structures except for the top-level tags. This commit introduces
the only remaining instance of such usage.
@lukebakken
Copy link
Contributor

Seems fine to me. Someone with more experience in coverage queries should review.

%% Copied and modified from riak_kv_pb_coverage:convert_list. Would
%% be nice to collapse them back together, probably with a closure,
%% but time and effort.
encode_cover_list(Entries) ->
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We generally try to make sure exported functions have specs. Internal ones are less important.

@hazen
Copy link

hazen commented Apr 19, 2016

👍 3d68557

@hazen hazen merged commit d5a80d4 into riak_ts-develop Apr 19, 2016
@hazen hazen deleted the fix-az-move_coverage_codec_from_riak_kv_to_tb branch April 19, 2016 02:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants